1. Field of the Invention
The invention generally relates to network communications, and, in particular, to discovering the path maximum transmission unit (PMTU) of a network connection.
2. Description of the Related Art
It is generally accepted that for efficient data transfer using an Internet Protocol (IP) connection, the data packet size should be as large as possible. The larger the packets, the lesser the overhead associated with transferring the entire data. However, if a packet is larger than what any given intermediate router along the communication path can process, the packet will be fragmented at that link. The maximum size packet that a router can process without fragmenting the packet is called a maximum transmission unit (MTU). The maximum size packet that can be transferred from a transmitting host to a receiving host without fragmentation is called path maximum transmission unit (PMTU). Consequently, the PMTU is a function of the maximum size packets that all intermediate routes in an IP connection can process without fragmenting the packets.
For efficient transmission, it is desirable to determine the PMTU for a given IP connection. One method of determining the PMTU is described in Request for Comments (RFC) 1191. RFC 1191 describes a procedure in which the transmitting host sends a discovery packet with an instruction that the packet not be fragmented (e.g., the “don't fragment” bit is set). If there is some MTU between the two communicating devices that is too small to pass the packet successfully, then the discovery packet is dropped and a “can't fragment” message is sent back to the transmitting source. For example, if a router along the transmission path has a lower MTU than the size of the discovery packet, the router drops the received packet and thereafter transmits a “can't fragment” message to the transmitting source. In some instances, the router may provide its MTU size to the transmitting source. The “can't fragment” message is sent using Internet Control Message Protocol (ICMP), which is an extension to IP and is used to support packets containing errors, control, and informational messages.
Upon receiving the “can't fragment” message, the transmitting source then knows to decrease the size of the packets. As such, the transmitting source retransmits the discovery packet using a new, lower MTU value. If the network path between the transmitting source and the receiving device includes several routers (or other network devices) with lower MTU values, then the discovery mechanism of RFC 1191 will require many iterations to discover an acceptable MTU. For example, assume that two routers exist between the transmitting host and the receiving host, and that the first router has an MTU value of 4392 bytes and the second router has an MTU value of 1500 bytes. Further, assume that the transmitting source sends a discovery packet of 9000 bytes (with the “can't fragment” indication set) intended for the receiving host. The discovery packet first arrives at the first router, which, upon determining that the packet size exceeds its MTU value, will discard the packet and send a “can't fragment” ICMP message to the transmitting source. In some instances, the first router may also transmit its MTU to the transmitting source.
The transmitting source, upon receiving the “can't fragment” message, retransmits a lower-size discovery packet (such as the size of the MTU value of the first router, if available). This time the first router will allow the second discovery because its size is less than the MTU of the first router. However, this discovery packet will be rejected by the second router, which, in this example, has a MTU value of 1500 bytes. The second router will thus discard the received discovery packet and transmit a “can't fragment” message to the transmitting source. In some instances, the second router may also transmit its MTU to the transmitting host. Upon receiving the ICMP message, the transmitting host will retransmit another discovery packet of a size that is acceptable to the second router. Thus, in the above described example, the transmission source takes at least two (2) iterations to determine the PMTU. As the number of routers (or hops) increase in a given path, then so can the number of iterations needed to determine the PMTU. As a result, the efficiency of the network transmission can suffer, thereby adversely affecting network performance.
The present invention is directed to addressing, or at least reducing, the effects of, one or more of the problems set forth above.